package com.tourscool.springboot.starter.seata;

import io.seata.core.context.RootContext;
import io.seata.spring.annotation.GlobalTransactional;
import org.springframework.stereotype.Component;

/** Just a test demo **/
@Component
public class AutoTransaction {

    @GlobalTransactional
    public String getXid() {
        System.out.println(RootContext.inGlobalTransaction());
        return RootContext.getXID();
    }

}
